<template>
  <el-table :data="tableData" style="width: 100%">
    <el-table-column prop="operationLogId" label="序号" />
    <el-table-column prop="uniqueTag" label="唯一标签" />
    <el-table-column prop="moduleName" label="模块名称" />
    <el-table-column prop="operationType" label="操作类型" >
      <template v-slot="scope">
         <span v-if="scope.row.operationType==1">新增</span>
         <span v-else-if="scope.row.operationType==2">修改</span>
         <span v-else-if="scope.row.operationType==3">删除</span>
         <span v-else-if="scope.row.operationType==4">查询</span>
      </template>
    </el-table-column>
    <el-table-column prop="description" label="描述" />
    <el-table-column prop="data" label="数据" />
  </el-table>
</template>

<script lang="ts" setup>
import axios from 'axios';
import { ref, reactive, onMounted } from 'vue';
import { useRouter, useRoute } from 'vue-router';
const router = useRouter();
const route = useRoute();
const apiurls = import.meta.env.VITE_APP_API_URL_BasicInformationCommon; //5176
const bpiurls = import.meta.env.VITE_APP_API_URL_BasicInformationWrite; //5013
const cpiurls = import.meta.env.VITE_APP_API_URL_RBACCommon; //5214
const dpiurls = import.meta.env.VITE_APP_API_URL_RBACWrite; //5268
const epiurls = import.meta.env.VITE_APP_API_URL_SalesManagementCommon; //5227
const fpiurls = import.meta.env.VITE_APP_API_URL_SalesManagementWrite; //5020
onMounted(() => {
  getLogsList();
});
const tableData: any = ref([]);
const getLogsList = () => {
  axios
    .get(apiurls+'/api/CustomerProfileReades/OperationLogQuery')
    .then((res) => {
      console.log(res.data.data);
      tableData.value = res.data.data;
    })
    .catch((err) => {
      console.log(err);
    });
};
</script>
